import { createApp } from "vue";
import App from "./App.vue";
import router from "./router";
import { setupStore } from "./store";
import { createPinia } from "pinia";
import piniaPluginPersistedstate from "pinia-plugin-persistedstate";

// 样式
import "@/styles/index.css";
// 通用字体
import "vfonts/Lato.css";
// 等宽字体
import "vfonts/FiraCode.css";
import { setupVuetify } from "@/plugins/vuetify.ts";

// 导入axios
import "@/plugins/axios";

const app = createApp(App);
const pinia = createPinia();
pinia.use(piniaPluginPersistedstate);

// 全局注册状态管理(store)
setupStore(app);

// Vuetify
setupVuetify(app);

app.use(router).mount("#app");

export default app;
